package hasthi.metamodel.utils;

import java.util.Collection;
import java.util.HashSet;

public class NamedList {
    private String name;
    private HashSet<Object> list = new HashSet<Object>();
    
    public NamedList() {}

    public NamedList(String name) {
        this.name = name;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }


    public boolean add(Object o) {
        return list.add(o);
    }

    public Collection<Object> getList(){
        return list;
    }

    public boolean remove(Object o) {
        return list.remove(o);
    }

    public boolean contains(Object o) {
        return list.contains(o);
    } 
    
    
    
    
//    @Override
//    protected Object clone() throws CloneNotSupportedException {
//        NamedList namedList = new NamedList(name);
//        namedList.addAll(list);
//        return namedList;
//    }
    
    
    
}
